Viewing 11 posts - 1 through 11 (of 11 total)
This is what I finally used:
DROP TABLE IF EXISTS #DataSource;
CREATE TABLE #DataSource
(
[ID] INT
,[GroupName] VARCHAR(12)
,[RuleName] VARCHAR(12)
...
December 13, 2019 at 2:58 pm
I forgot to mention, the column list is not fixed, its dynamic. Your solution only works for a fixed column list.
This is what I started with, but haven't found a...
December 11, 2019 at 9:10 pm
Unless the data is delimited with the same number of spaces with the same type of data in the same columns, its not the simplest of tasks. I agree with...
April 26, 2019 at 2:10 pm
Which SQL Server are you on?
May look at the script library (https://www.sqlservercentral.com/scripts) for a String Split function.
April 18, 2019 at 7:54 pm
DECLARE @string VARCHAR(50) = '1,2,3,4,5' ;
DECLARE @separator CHAR(1) = ',' ;
SELECT * FROM [Country] WHERE [Id] IN ( SELECT * FROM STRING_SPLIT( @string , @separator ) ;
April 18, 2019 at 7:24 pm
Sticky situations. On one hand people are entitled to their privacy. But, on the other hand, entities (companies, governments, etc.) have security needs. Example: Landlords are looking for ways to...
April 18, 2019 at 5:04 pm
If I'm understanding you correctly, the users do not have connect privileges to the database. Assuming you actually want them to be able to connect to the database, the following...
April 18, 2019 at 4:39 pm
The following SQL query retrieves only the time as you'd like:
SELECT [TimeOnly] = FORMAT( [DateTimeCol] , N'hh\:mm\:ss' )
FROM [Job info$] ;
Now, if you need to persist the...
April 18, 2019 at 4:21 pm
No, the temp table is for illustration only. The query is something like:
SELECT [Time Reported] ,
[TimeOnly] = CONVERT( TIME ,...
April 17, 2019 at 4:29 pm
Try something like below. Replace the temp table and column names with you table and columns names) this:
CREATE TABLE [#TimeReported]
(
[ID] ...
April 17, 2019 at 3:11 pm
I prefer to use UTC at both the server level and the database level and perform all internal Application and Database logic with UTC. Logic in the UI (or...
April 17, 2019 at 2:36 pm
Viewing 11 posts - 1 through 11 (of 11 total)