The tag has no usage guidance.

learn more… | top users | synonyms (4)

2
votes
1answer
43 views

SQL Server: Programatically trigger export of db schema

SQL Server 2014, Std edition We have seen and used, over the years, a variety of sprocs and non-MS tools to export the DB schema. The way we really like to do this is the built in utility, in SSMS, ...
2
votes
1answer
361 views

How do you generate the DDL that created a db2 luw database?

There are various options for db2look you can use to see the DDL for just about every object in the database except the command that created the database itself. Is there any way with db2look, or ...
1
vote
1answer
20 views

select two tables and print the columns side by side with matching key in hive

I have the below tables: table_1 name_1 id_1 value_1 avi 1 21 adi 2 X table_2 name_2 id_2 value_2 avi 1 21 adi 2 22 metadata_info: can be read ...
1
vote
1answer
703 views

pgpool-II doesn't execute my failover script

I have been installed pgpool-II 3.3.4 from source. I have two pgpool nodes and I also used the watchdog configuration to get a pgpool services with High Availability. When I stop one, the other wake ...
0
votes
1answer
23 views

Is it possible to take the table level backup in mysql using any of the script?

I am new to MySQL and I am in need of the script which is taking backup of multiple tables from the multiple databases in single file in MySQL?
0
votes
1answer
64 views

Generate Schema Only Script from SQL Server 2012 to SQL Server 2008R2

Hi this is the first time that I've encounter this error in generating script for my database, what do you think causes this error? Thanks. Please see image.
0
votes
1answer
791 views

Running Oracle Export Utility within a Shell script

I have wasted a lot of time on this. Any ideas of what I am doing wrong here? Script in bash #!/usr/bin/bash . . . /export/home/app/oracle/product/10.2.0/bin/exp $uname/$passw \ ...
0
votes
1answer
71 views

databases cross references baselines

We have on several databases on same instances, some stored procedures have references to tables on other databases. We are in the middle of a big project to take our database under source control. ...
0
votes
1answer
310 views

Migration script fires 'The data definition language (DDL) command cannot be executed at the Subscriber'

Yesterday I had run a migration script, produced by Visual Studio 2008 schema compare option, on a SQL Server 2008 database. It had run correctly. But today, when I executed the same script, it threw ...
5
votes
0answers
5k views

SQL*Plus, @, and relative paths

Somehow, it seems that SQL*Plus (at least on Windows) is unable to locate a script with a relative path when called with @@ and when the path starts with a single or double dot. For example, under ...
2
votes
0answers
215 views

How to get status of “opatch prereq CheckApplicable” via script

I want to check if a patch is Applicable via opatch prereq CheckApplicable -oh <oracle home> -ph <patch home> but the returncode is always 0! It doesn't matter if the text output says ...
2
votes
0answers
379 views

Scripting Local Policy Perform Volume Maintenance Tasks

I am working on an automated SQL 2012 install process on Windows 2012 R2 and have everything complete except for one task. My process launches secpol.msc but I am still required to drill in and ...
1
vote
0answers
44 views

What should be the best practice to alter the table using the script to shift columns

I have a MySQL table which has columns 93 in it. All first 92 columns are INT(11) and the last column is of type DATE. |number|0|1|2|3........|88|89|90|ddate| | | | | | ........| | | | | ...
1
vote
0answers
39 views

Disable the Task action button

How can I disable the "Tasks ->" button in SQL Server Management Studio? I need to prevent users scripting objects.
1
vote
0answers
32 views

TSQL Stored Procedure - Granting general user access to specific sproc

I'm attempting to alter a sproc that needs the line added : grant exec on dbo.sproc_name to exec_proc. I believe the admin setup the exec_proc as a group. I added this grant line following the final ...
1
vote
0answers
85 views

Parallel insert in db2

I am trying to import from 8 files and insert into a single table in db2. I am running 8 .sql files that will do the task, but only one of them actually seem to be running and inserting into table. ...
1
vote
0answers
3k views

Management Studio Generate Script Errors

I am trying to generate a script (right click database, tasks, generate scripts, tables) from SQL Server Management Studio 2008 R2 Express and I keep getting an error. I read somewhere that it could ...
0
votes
0answers
10 views

What is the best practice of storing mysql connection details to use in ruby/python scripts

I have ruby and python scripts that connect to mysql DBs. They are controlled in github and can populate to different servers. They run in a schedule way (not adhoc). What is the best practice of ...
0
votes
0answers
44 views

begin end block in MySQL

I have a compound statement of begin end block consisting of some SQL statement as mentioned below. lab_name: BEGIN truncate table table_name; insert into table_name (a,b,c,d,e,f) ...
0
votes
0answers
20 views

Finding the least binary logs amount multiple slaves connected in master

I have the master server with multiple slaves (for ex: 4). I would like to purge the binary logs after checking the processed binlogs on all slaves. I wrote the below script to find the least ...
0
votes
0answers
107 views

How to generate “Too many connections” error using mysql cli over ssh

I have a script which queries for blocks of data, one after another, from a remote MySQL database via ssh and mysql cli and pipes the result output to stdin of a local executable. Loosely scripted, ...
0
votes
0answers
474 views

scipt for rman configuration & database backup in dataguard environment

environment Oracle Solaris 10 -> 5.10 Generic_147147-26 sun4v sparc Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit production Oracle Solaris Cluster 3.3u2 for Solaris 10 sparc ...
0
votes
0answers
360 views

MySQL Script to automate creation of audit (history) tables and triggers?

For regulatory and fraud requirements, we need to record every change to most of the tables in the DB. The way we did this very successfully with a previous project is to have a copy of each table, ...
0
votes
0answers
122 views

cronjob(script) that sends(mail x) the query co-ordinator SID whenever parallels are invoked in queries

i am a junior dba im looking for help with a shell script that needs to be put in the crontab(which runs every 15min) which sends(via mail x) the query coordinator session id(SID) and other details ...
0
votes
0answers
4k views

execute .sql script inside an anonymous pl/sql block which is invoked by a shell script

I got a shell script which connects to SQLPLUS and executes the .sql file like below: read a x=`echo $a | cut -d , -f 1` y=`echo $a | sed 's/.*,//'` c=`echo $USER | cut -c -2`"OPR"`echo $USER | ...