I need a field containing 00:00:00 as numeric (not text) in VFP to export dbf...
I am creating a series of .csv files to import records in Sage 300 Payroll using low level file functions. There is one field called Valtime that requires 00:00:00 as a "number" not text with Quotes...
View ArticleCannot call methods on bigint
Hi,I'm getting the error 'Cannot call methods on bigint' when executing a query in Management Studio.It's happened after in a where clause I used a field(docmentid) of bigint data type to compare with...
View Articleadd RECOMPILE for specific query server wide
Hi,I've SQL 2017 and i have a query performance problem. i did try to play with all those trace flag (4199,4136,4137,9481)server wide and play with the indexes and stats and the query is still running...
View ArticleT-SQL to convert Datetime and DatetimeOffset to Zulu Format
How to convert datetime and datetimeoffset to zulu format in Sql server 2014 and aboveHow does the function SYSDATETIMEOFFSET() works - Does it calculate the offset of the server in which SQL Server is...
View ArticleExtract values from the String filed in SQL server
I have nvarchar field in a SQL server table that contains html string where value need be separated into twoadditional fields and data can be of varying lengths.Number of Sales: <Area="ABC"...
View ArticleRow wise Total in Pivot table ,coming wrong
i am trying to calculating total row wise in Pivot,which is coming wrong.CREATE TABLE #SalesOrder (OrderNo INT,Order_Ref_No VARCHAR(50), Order_date date,Status Varchar(50)); CREATE TABLE #OrderDetail...
View ArticleTake one cell's value and convert it into a string for display in a label.
Hi,I know this is probably simple but...I want to select one value from a cell in our MSSQL database, and turn it into a string and put it in a label on our asp.net website.myEmailTemplateCommand = New...
View ArticleBest Practice filtering a Datetime Data Column by a provided StartDate and...
So I'm sure this has been beaten to death...I think even I myself have beaten this to death.We are wondering what the SQL Server Best Practice is when it comes to creating a SQL Server Stored Procedure...
View ArticleHello Friends, In below given query i want the Aging column's outputs in...
Select Work_Order_ID,summary,ISNULL(Request_Assignee, 'Unassigned') as Request_Assignee, CAST(DATEADD(s, Submit_Date, 'Jan 1, 1970') as nvarchar) as Submit_Date , CAST(DATEADD(s, Last_Modified_Date,...
View ArticleScripting
I don't know what the "scripting" means in SQL Server.(I have experience in T-SQL but not familiar with this term)Does it mean general T-SQL statement?Can anybody give me some idea and example for me...
View ArticleSql Server 2019 Standard 64bit Slow Performance Vs Sql Server 2012 Express...
Hello, I try to migrate my database from Sql Server 2012 Express (Sp1) to Sql Server 2019 Standard 64bit and I getting very bad query performance results .Same DB , Same Table, Same Data , same query...
View ArticleSales revenue by country
I have three tablesmotorcyle_model: id, name, pricecountry: id, nameSales: model_id, country_id, quantity, sales_date All the country wise sale records of its motorcycles in table sales, storing...
View ArticleWarning: Null value is eliminated by an aggregate or other SET operation ?
I working on SQL server 2012 I face issue I can't solve this warning Warning: Null value is eliminated by an aggregate or other SET operation so How to solve this warning and not display again my query...
View ArticleCan SQL Server graph query d orecursive?
SQL Server support graph table start from version 2017,I am wondering if graph query support recursive?below is the example:CREATE TABLE Person ( ID INTEGER PRIMARY KEY, name VARCHAR(100) ) ;CREATE...
View ArticleRTRIM Not working
Hi guys,I have a strange issue when trying to trim some trailing spaces off a string.When I do select RTRIM([ErrorDescription])from [employer].[T_BulkUpLoadNewStarters_Errors]I get (note the two extra...
View ArticleEXEC sp_tables_ex random fail
Hi I installed ACE driver 2010 64 bits on my SQL 2017 64bitsI created a Linked Server to an Excel fileSELECT * FROM myExcelLinkedServer...[Sheet1$] -- Works 100% of the timebutEXEC sp_tables_ex...
View ArticleOne time history load into dimension table
I have a slowly changing dimension table that keeps track record of our current patient from the patients current location.There is also a history table.I want to load the history table into the...
View Articlecreating tables in a database by using proper ANSI SQL syntax 98-364 database...
Hi We are working on 98-364 exam guide and one of the requirements is "creating tables in a database by using proper ANSI SQL syntax"Is someone able to give me T-SQL CREATE TABLE statement that is NOT...
View Article"SELECT * INTO table FROM" a stored procedure? Possible?
I did a search and read a few solutions but they just don't make too much sense to me. Forgive my newbie-ness but I'm still pretty new when it comes to stored procedures. I'm still learning every...
View ArticleT-SQL to Update duplicate records
Ok Im not sure this can even be done but I have a table that has a field with duplicates in it, 970 of them to be exact.What Id like to do is within this field, find duplicate entries and replace one...
View Article