Skip to main content
Filter by
Sorted by
Tagged with
1 vote
1 answer
132 views

I am attempting to determine how to most efficiently identify the sets consisting of the least number of terms for a group of disjoint sets. I have a set of Boxes (B##) and Cartons (S##) which are ...
Erg's user avatar
  • 79
-4 votes
1 answer
90 views

I am using left join in my query, and for some reason it's showing the same record two times. if I remove this join (left JOIN tbl_item AS i ON sd.ItemIDsale = i.itemid) then the result will be not ...
Jayanta Modak's user avatar
0 votes
0 answers
126 views

I need a way to obtain a list of all attributes / hierarchies of all dimensions of a given cube. In the Internet I have found that following SSAS DMV for doing a similar job: SELECT [CATALOG_NAME] as [...
HandsomePig's user avatar
0 votes
0 answers
132 views

I need to connect to a "very" old SQL Server running on v10.50.2550.0 (Win NT 6.1 (7601)) (SQL Server 2008 R2). Yes I know it should be updated but there is no way for this atm! The Docker ...
Florian Draxler's user avatar
1 vote
1 answer
132 views

I am using Laravel 8.40 and trying to migrate my WebApp to SQL Server 2008 R2 SP1 on MySQL everything works fine, but after I migrated my database over (with plain SQL commands) and when trying my app ...
NinaNuska's user avatar
2 votes
1 answer
126 views

I'm working in Java 1.8 and with a SQL Server 2008 R2 (I'm fully aware that it's not supported since a long time, but it's unfortunately not in my hand) which only support TLSv1. I use ms-sql jdbc to ...
Thibault Coudert's user avatar
0 votes
1 answer
179 views

I want to add a filter to a query which grabs dates till last 5 WORKING DAYS. declare @DataRetentionPeriod INT =5 Delete FROM dbo.table1 pt WHERE CONVERT(varchar,pt.ptStampDateTime, 112) < ...
user25935915's user avatar
1 vote
0 answers
116 views

I can't do anything with legacy database, can't migrate or update, I have to read some data from it. Personally, I'd love to migrate, but I can't. Is there any way to connect Laravel 11 on PHP 8.2 ...
Rustam Anvarov's user avatar
0 votes
1 answer
102 views

I have a legacy database that is running SQL Server 2008 R2 Express Edition. Today, I was trying to use sqlacodegen to generate SQLAlchemy classes via the pyodbc package. I was able to connect to the ...
Andrew's user avatar
  • 669
0 votes
0 answers
64 views

When I execute my code on my ASP.NET website, I get this error: Transaction count after EXECUTE indicates a mismatching number of BEGIN and COMMIT statements. Previous count = 1, current count = 0. ...
Miguel Henrique Pereira's user avatar
0 votes
0 answers
88 views

I working on for maintaining a legacy project, my PowerBuilder version is 12.5 and my SQL Server is 2008 R2, I encountered a problem which when I tried to update the records within a datawindow in a ...
Tommas Lees's user avatar
0 votes
0 answers
63 views

I am trying to execute a stored procedure for the list of values from a query using a while loop but the while loop is taking forever to complete. CREATE PROCEDURE ItemsToBeCleared @BatchDays INT ...
PrettyCode's user avatar
1 vote
3 answers
87 views

My core table data looks like this. It is keeping track of order statuses. ID PartNum EnteredOn PickedTime DeliveredTime 100 50A 2024-03-28 08:59:13.727 2024-03-28 09:30:20.237 2024-03-28 09:56:42.570 ...
Bushmatic's user avatar
1 vote
1 answer
56 views

I have a table in Microsoft SQL Server called Downtime that looks like this (I have omitted some irrelevant columns and many entries): ID StartTime EndTime 5 2024-03-27 09:07:20.653 2024-03-27 09:09:...
Bushmatic's user avatar
0 votes
2 answers
409 views

I've hit an interesting problem in our system. A design decision was made to include IDs in a comma separated string which are referenced in the day-to-day functioning of the system. It wasn't causing ...
The Betpet's user avatar
0 votes
1 answer
70 views

I would like get help in the following Data. We have hand punch machines which saves exit and entry log, each exit and entry log stores a different row for an employee. Table: Date circuit_label ...
Lenah Abdulrahman's user avatar
-1 votes
1 answer
150 views

I'm looking for a solution to get children's values in a single cell, I've found out about STUFF but when I'm trying to apply it to a self-referencing table it does not work. Neither CONCAT nor ...
V. Lernout's user avatar
0 votes
1 answer
67 views

I have a SSIS package in visual studio 2008 which just contains a simple data flow task (ole DB source, flat file destination). However I need to add a constraint so that the task only executes on ...
Trevor McCarthy's user avatar
0 votes
1 answer
69 views

I have an old database that unfortunately a choice was made when it was designed that one of the largest tables, which contains photos (table called Photos) and has a PK of type uniqueidentifier. This ...
NDallasDan's user avatar
0 votes
0 answers
25 views

I'm trying to identify some slow and databases and queries on SQL Server 2008 R2. I have been able to filter by time and display the database name succefully. However the DatabaseName always says '...
danielson317's user avatar
  • 3,318
1 vote
2 answers
142 views

I'm using MS SQL Server. I have 2 tables: Table1 stores information about the individual object number (Object_id), the number of its property (Prop_id) and the value of this property (Value). Example ...
Twinkles's user avatar
0 votes
0 answers
126 views

Here is my specifications: My SQL Server: Microsoft SQL Server Enterprise 2019 (v15.0.2000.5) My Windows : Windows 10 Enterprise LTSC 2021 My Office : Office 2016 My CSV file full path: F:\TaxStuff\...
مجتبی حکیمیان's user avatar
0 votes
1 answer
158 views

It is possible to create the database using SQL Server 2008 R2, once created with all tables and stored procedures etc. then copy and paste it into the Visual Studio App_Data folder to be used as ...
AlDiz's user avatar
  • 41
0 votes
0 answers
188 views

I'm trying to save a SSIS package for an export of a query to a .csv file. The problem is that the PackageFormatVersion of said SSIS package is 8 (for SQL Server 2016 onwards) but the instance I'm ...
Ale Yanczuk's user avatar
-2 votes
1 answer
73 views

I have 2 tables that I need to populate with 100 rows from a remote linked database. The first table is easy, because I can just do a simple INSERT from a SELECT. However, I also need to populate a ...
SkyeBoniwell's user avatar
  • 7,246
-2 votes
1 answer
406 views

enter image description here I entered the wrong column name and included [] as shown above [avail_memory_mb], I want to remove [] using the syntax, how do I do that? I have tried using syntax EXEC ...
AgnesHira's user avatar
1 vote
1 answer
328 views

I am querying data from BQ. I have to insert it to SQL Server 2008. pseudocode: # get results from bigquery client = bigquery.Client() result = client.query(sql).result() # create parametrized ...
mkylfnur's user avatar
1 vote
1 answer
496 views

I am importing a number of CSV files into a database. The aim is to take the data from the files but also write the filename of the associated CSV file to each of the database rows. I am using a ...
Optimaximal's user avatar
0 votes
0 answers
437 views

I am making a simple WinForms application for a client. The application's database does not run on their PC because they get the message ...MDF file cannot be opened because it is version 904. The ...
sami's user avatar
  • 25
0 votes
2 answers
1k views

I've reviewed (and tried to use) SQL Server 2008 trigger on create table without success. I currently upload a CSV file to a table called DataTMP. The data in this file is ETL'd into another table ...
Seamus's user avatar
  • 93
-1 votes
1 answer
588 views

I have 2 queries in SSMS which are executing fine. I need to join them together, and I'm not sure how to (I'm a beginner at T-SQL). The first script is pulling data from a database and transforming ...
Rwlsxn's user avatar
  • 1
0 votes
0 answers
154 views

I have the following data: Employee Date Amount Emp 1 01/01/2023 1.50 Emp 1 01/01/2023 7.5 LB Emp 1 02/01/2023 0.00 Emp 1 02/01/2023 1.5 LB Emp 1 03/01/2023 7.5 LB I would like to pivot the table such ...
Lavie 's user avatar
  • 13
0 votes
0 answers
35 views

strong textaI have a query that returns at most one row from a table with a FILESTREAM column, using the following condition: select * from TABLE_WITH_FILESTREAM_BLOBS where BLOB IS NULL AND ID_BLOB = ...
UnDiUdin's user avatar
  • 15.5k
0 votes
1 answer
209 views

I am getting an invalid column name error and I can't understand why... SELECT TOP (1000) i.[t207f005_classification_code] ,i.[t207f010_sort_key] ,i.[t207f015_date_effective] ,i.[...
Carl Blunck's user avatar
0 votes
0 answers
108 views

Here is my SQL query: CREATE PROCEDURE User_CRUD @Action varchar(20), @eno int, @ename varchar(50), @salary money AS IF @Action = 'Insert' BEGIN INSERT INTO employee (...
Nani's user avatar
  • 9
0 votes
1 answer
92 views

CType Material CoCd Plnt SOrg SoldTo ShipTo Customer Vendor SerProv POrg Year per UoM NSapRel Amount Crcy ChangedOn Time Changedby SAPdate SAPTime SAPUser PB00 775515 100 GA 7500000678 PO04 2022 100 ...
user3900603's user avatar
0 votes
1 answer
894 views

This is our output: category Rev trandate BankAccNo Fee Credit Cards 1 01-09-2022 10000175090 576 Credit Cards 1 01-09-2022 10000175090 576 Loan 2.2 01-01-2022 10000175090 678 Loan 2.2 01-02-2022 ...
Tejas's user avatar
  • 21
0 votes
2 answers
365 views

I want to create a new view in SQL Server 2008 R2. Given is a col called "ADRESS", based on which I want to create a col called "CompanyID". I want to add a suffix, which counts +1 ...
tman's user avatar
  • 3
0 votes
1 answer
36 views

Suppose I have items in a table that resemble the following: Item FamilyCode ABR123 ABR ABR456 ABR BCL369 BCL BCL987 BCL AEL877 AEL I would like to notate whether an item is part of a family based on ...
user avatar
-1 votes
1 answer
394 views

I am writing a stored procedure with DB name as input parameter. I am creating some physical tables dynamically. If a table already exists then I need to delete the Table. DECLARE @TargetDBName ...
Tech Learner's user avatar
  • 1,327
-2 votes
1 answer
149 views

I have a update statement that will update one column in the database. The column is defined as varchar(500) and the string contains 153 characters. But while updating, it updates only 100 characters. ...
Mayur Kendre's user avatar
0 votes
0 answers
232 views

In SQL server 2019, I have a table having 10 columns. There are 10 user logins. Each user should see only three columns as per their choice. I need to keep the data encrypted in the database. Even ...
Sheikh Nazimuddin's user avatar
0 votes
1 answer
194 views

I'm used to Powerquery's sequential command structure where each new step references the output of the previous one, like ... Declare source Table1 with columns a, b, c. [RESULT: a, b, c] Calculate ...
overhear's user avatar
0 votes
1 answer
83 views

I'm hoping that someone is willing to help. I'm new to SQL and struggling to get a simple query debugged. I want to create a simple frequency table to see how many values are missing (i.e. = 00000000) ...
overhear's user avatar
0 votes
0 answers
80 views

I'm running a query every 5 minutes to extract records created/updated in the 5 minutes leading up to the scheduled job. Occasionally the query will omit records that appear to be in the process of ...
KalebK's user avatar
  • 9
1 vote
1 answer
406 views

I have ploughed through the massive amount of queries on here relating to SUBSTRING and CHARINDEX but I cannot find one that answers my query. I am extracting a single part of a long piece of text but ...
Caroline Allen's user avatar
1 vote
1 answer
100 views

RTrim is not working when sentence is Arabic. Below is the example declare @name nvarchar(50); set @name = N' لللييب بي  '; select rtrim(ltrim(@name)); English one is working declare @name nvarchar(...
Basit Sarguroh's user avatar
-3 votes
1 answer
99 views

The error is in the first ORDER BY which is on the second line. The code runs perfectly fine, if I remove the first ORDER BY. Here is the code : SELECT dea.continent, dea.location, dea....
Divyajeet Singh's user avatar
0 votes
1 answer
107 views

I need to make a copy of a production Database and restore it to a different database on the same production server. I do not have a development SQL Server to practice on. The DB to be copied has Full ...
mpdillon's user avatar
1 vote
2 answers
256 views

I have a number of records in the table as shown below, where I have put the structure of the table and the records that are in conflict for you. CREATE TABLE [dbo].[TblHilfeStrings] ( [Id] [int] ...
schemitzhiloruin's user avatar

1
2 3 4 5
226