It’s been a little while since I’ve messed with SQL and I’m picking it back up for a course. I need to create a table of table name, column name, constraint name, and constraint type for all tables with my user, but every time I try, I’m getting a missing right parenthesis error. Here&…
Tag: sql
How to get count of particular column value from total number of records and display difference in two different columns in SQL Server
I am trying to get difference between total records and a column (Is_Registered) to get Month wise matrics of how many registered in particular month and how many are pending Actual Data Expected Output -As shown in actual data, out of 8 users(records) 2 are registered in Jan and 6 are not ,in February total …
Why does my SQL query not have any columns?
I’m not an expert by any means but I write SQL queries fairly regularly. I am pulling data via Crystal Reports 2013 from SQL Server 2016 (not positive about the version). Just as an aside, CR permits parameters so that’s what {?DateStart} is. {?DateStart} and {?DateEnd} are regular dates, {?Servic…
Finding only active items from a column of ‘added’ / ‘removed’
I’m attempting to write a query that tries to find the most recent items. Given a set of parent_service_items find the relevant child service items and return a list of them. For finding just the direct children, I’m using query which simply finds all the associated children. I then use this query…
Assign new ID to each row dynamically
I have a table with over 9000 rows. Each row has some weird ID. I would like to re-set each ID as following 000001,000002,000003, etc… (dynamically). Is there an easy way of doing it?
i want to send a javascript prompt answer to my sql databse, is this possible or is there a better way to do this? [closed]
currently have this code activated by a html button: function popup() { var group = prompt(“Please enter group name”); if (group != null || group != “”) { window….
How to access a table with username with special characters in Oracle sql Developer
I have the following usernames/schema: shopping shops[shopping] In both users I created a table named “SHOP_TAKE_CART”, I use shopping for testing purposes and shops[shopping] to publish …
How I can select a column where in another column I need a specific things
I have a pyspark data frame. How I can select a column where in another column I need a specific things. suppose I have n columns. for 2 columns I have A. B. a b a c d f I want all column B. …
Calculation view for material to material transfer
I have a table Tab1 with two rows +——-+———-+————–+———-+——–+ | DOC# | Material | Debit/Credit | Quantity | Amount | +——-+———-+————–+———-+…
oracle sql contain
I have table with values in columns like colname TMC_MCH,OTA_MCH,CONSOL_MCH,RETAIL_MCH,TOUROP_MCH,SPEC_MCH,QRACTO_MCH RETAIL_MCH RETAIL_MCH,CONSOL_MCH CONSOL_MCH OTA_MCH I need to run query to fetch …