Hello,
We are trying to quantile a large number of rows.
We have ran this code before and it ran fine.
The code is:
Select
Cust_ID
,quantile(100, Profit - ZeroIfNull(ABS(Acc_Amt))/12) as Perc
From
Customer_Table
We have tried removing the calculation, so we are quantiling a single value...
Hello,
I have a small SQL Server running that services some users.
I wish to set up an alert when an extarnal feed fails or a stored Procedure completes etc.
In order to inform me of when an extarnal feed fails, I need to put a value into a table.
When a value is placed in this table I want...
Hello,
I have got a DTS job that extracts from a table held in an Access databse held on the D:\ drive of my work terminal. This DTS Job is held on a separate SQL 2000 Server over a LAN.
When I execute this DTS Job manually, it is fine - it finds MY work station version of the Access Database...
Hello,
I know who to return an error code from within a stored procedure, using SQLCODE. Is there a way to get the full corresponding error message back too?
i.e. Table_1 does not exist
I have tried SQLERRM, but this is not recognised.
Do I have to write my own, or am I missing something...
Hello,
I have a stored procedure and want to execute some derived SQL.
I have tried
CALL DBC.SYSEXECSQL ('Select ' || :Measure_Calc || ';');
But do not have access
I have also tried
EXEC SQL 'Select ' || :Measure_Calc || ';'
END EXEC;
The second one should work, according to the...
Hello,
I have a text field:
@(999104,1)
and I want to pick out
'999104' and then '1'
Easy!
But what heppens if:
@(999104,1) + @(999105,2)
and I want to obtain
'999104' & '1' and then '999105' '2'
I have a cursor that is set up to bring in the rows from a table, and will try to find a loop...
Hello,
I would like to take a text string, find a numeric, and substring it from the numerical value - 1
e.g.
'BS12 6QQ' I would like to turn into 'BS'
I also need to turn the above into
'BS12'
with the proviso you could potentially have BS1 6QQ, and I would want to return 'BS1'.
so far I...
Hello,
Is there a large benfit to be had collecting Stats on Group by columns.
If so, can I use a composed stats (Field_1, Field_2 etc)?
I don't want to create an INDEX unless necessary - I doubt this would even help?
I do this insert and group by 11 times due to spool issues, and our...
Hello,
Is there a way of getting the IP address of my conncetion, or of the system though the Teradata system tables?
They have given us a new system and it has knocked out my host file...
Thanks in advance,
Liam1.
Hello,
We are having a bit of a 'discussion' in our office...
Wht does COLLECT STATS actually do?
If I have a column (Col_1) on a table (Tab_1) - does the collect stats basically carry out:
Select
Count (*)
,Col_1
From
Tab_1
Group by 2;
Or does it do more complex things?
You can use...
Hello,
For the past month I have been continuously been locked out of my machine.
I changed my password a month ago, and this is when the trouble started. All Task Manager applications have been switched off, and the NT Roaming Profile has been re-built twice.
Microsoft Office is installed...
Hello,
I have been using the script
.logon NameInHostFile/UserName,PWord
as in DOT Logon connection name in host file FORWARD SLASH username COMMA password
This seems to have stopped working over night.
"Error Invalid Logon!!" is generated.
I cannot put my password within the same...
Hello,
When I am inserting lots of data into an empty table
I have noticed that under my user ID, that when the actual insert is taking place, our Teradata box seems to remove the data one AMP at a time.
AMP Spool
1 100
2 100
3 100
4 0
5 0
etc
The data seems...
Hello,
I have an Access database that I would like to execute a function at a set time, i.e. 21:00hrs when the database is not busy.
At the moment I use a loop as follows,
dim dSubTime as time
'this is a user defined time
Do
Loop While dSubTime <> Time
Call fcnDoSomething
i.e. do...
Hello,
I am trying to run a batch file from Access. I'm not very good at VBA, but what I would like to do is:
Return a code to my Access database when the application closes.
e.g
Shell(File.Bat)
*BTEQ Opens*
*do something for 5 minutes*
*BTEQ Closes
now my bit:
a variable is...
Hello,
I am trying to run a batch file from Access. I'm not very good at VBA, but what I would like to do is:
Return a code to my Access database when the application closes.
e.g
Shell(File.Bat)
*BTEQ Opens*
*do something for 5 minutes*
*BTEQ Closes
now my bit:
a variable is...
Hello,
I am trying to use a Microsoft Access module to execute a query in BTEQWin.
I can start BTEQWin fine, but how do I send it something like
.run C:\SQL.txt
Thanks in advance,
Liam1
Hello,
I would like to know a method to calculate the size of a secondary index/indices.
Is this possible without calculating the size of the data held within the table and then jiggering about with figures?
The reason being I'm trying to explain to some one that they might not need 13 SI's...
Hello,
A colleague has used the .EXPORT command in BTEQ for Windows, but not specified a file name.
When she uses the RUN command, the file still exists, but she is unable to find it anywhere using Explorer/Search.
We have looked in the BTWin.exe directory, but there does not seem to be a...
Hello all,
I am trying to capture the error code returned by Teradata.
We are on a V2R5.0 box, and do not seem to have an ErrorLog table within DBC.
I would like to be able to capture this error code and put it into a table, or even pass it back to a VBA script.
I have managed to use the .If...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.