Viewing 15 posts - 241 through 255 (of 430 total)
Understanding that is, schema name is required for calling scalar functions. i have changed my requirement.
i made three schemas s1 s2 s3, then i made s1 as public ,...
July 15, 2022 at 7:24 pm
before we waste more time with this can you tell us what is the db engine/software you are using and why using a CTE is not possible - and...
July 15, 2022 at 3:33 pm
Another reason to always use the schema is that the default schema can change depending on schema scope. I stumbled across this recently and I was going to describe it,...
July 14, 2022 at 7:55 pm
This appears to be a follow-up to this post. https://www.sqlservercentral.com/forums/topic/how-to-refactor-code-with-cte
The OP states that cte's are not supported. A solution using derived tables was offered, but not acknowledged. If the platform...
July 14, 2022 at 6:14 pm
I can't tell what information is stored in StoreOrder and I hesitate to join to it unless StoreCode and ProductCode are unique. I have added the join, but it will...
July 13, 2022 at 10:12 pm
What question are you trying to answer? I am guessing what you need, but does it look anything like this? (There may be typos as I do not have tables...
July 13, 2022 at 7:43 pm
I actually tried it that way prior to the where clause way. It does work, but the update will update all the matched records since there is no filter...
July 13, 2022 at 3:47 pm
Does this work?
merge dbo.qsr_store store
using dbo.qsr_store_staging staging on store.id = staging.id and store.brand_code = staging.brand_code
when matched and (store.golive_date <> staging.golive_date or store.store_name <> staging.store_name) then
update set store.golive_date...
July 12, 2022 at 8:46 pm
This is a start. I would check every section for accuracy, especially the use of sys.sql_expression_dependencies.
WITH Tabs AS
(
SELECT DISTINCT b.[name] AS SchemaName, a.[name] as TableName, a.object_id,
...
July 11, 2022 at 11:21 pm
Is it possible that the optimiser is confused by the absence of else in the case statements in the OptionsetMetadata view? Possibly it thinks there will be a null returned,...
July 8, 2022 at 8:00 pm
Do you need left joins for all the joins?
Can you avoid a group by, by replacing the two left joins with a single left join to a union of the...
July 7, 2022 at 7:59 pm
Alternatively you could nest the ifs
if(ar.ardelay > 0, Yes,if(aj.apdelay > 0 Yes, No)) ,
I believe your error message refers to the use of 'then' when you need...
July 7, 2022 at 6:07 pm
I am not familiar with MySQL, and I don't know what your error message is, but you could try a case statement. You would probably need to include the case...
July 7, 2022 at 6:02 pm
Are these worksheets or tables that have been created in the Excel WorkBook? if so then try deleting them in Excel. If they are tables, they might all be defined...
July 6, 2022 at 8:30 pm
By first and second do you mean according to CreationDate? ID looks like it would also serve as an ordering column, but I did not want to make that assumption.
What...
July 5, 2022 at 11:23 pm
Viewing 15 posts - 241 through 255 (of 430 total)