Quantcast
Channel: dBforums – Everything on Databases, Design, Developers and Administrators
Viewing all 13329 articles
Browse latest View live

Data dictionary for MongoDB

$
0
0
I am working on MongoDB and trying to design and generate a simple data-dictionary. I have a simple PHP application to accept sample records and generate a data-dictionary based on the sample records which is going to be used for the specific purpose only. Please help

Thanks

Instance Start but fails on connect db2 9.5 fixpack 10

$
0
0
looking to see if I can get this instance functional without a db restore. This immediately after my attempt to connect to database from the db2diag file.

more db2diag.log

2015-01-23-07.10.06.488712-360 I1A1368 LEVEL: Event
PID : 5409 TID : 12 PROC : db2sysc
INSTANCE: db2pcni NODE : 000 DB : PCNLIST
APPHDL : 0-7 APPID: *LOCAL.db2pcni.150123131006
AUTHID : DB2PCNI
EDUID : 12 EDUNAME: db2agent (PCNLIST)
FUNCTION: DB2 UDB, RAS/PD component, pdLogInternal, probe:120
START : New Diagnostic Log file
DATA #1 : Build Level, 152 bytes
Instance "db2pcni" uses "64" bits and DB2 code release "SQL0905A"
with level identifier "060B0107".
Informational tokens are "DB2 v9.5.0.10", "s120809", "IP23361", Fix Pack "10".
DATA #2 : System Info, 1592 bytes
System: SunOS oddctudb01 5.10 Generic_142900-12 sun4u
CPU: total:4 online:4 Cores per socket:1 Threading degree per core:1
Physical Memory(MB): total:16384 free:13539
Virtual Memory(MB): total:34771 free:31926
Swap Memory(MB): total:18387 free:18387
Cur cpu time limit (seconds) = 0xFFFFFFFFFFFFFFFD
Cur file size limit (bytes) = 0xFFFFFFFFFFFFFFFD
Cur data size (bytes) = 0xFFFFFFFFFFFFFFFD
Cur stack size (bytes) = 0x0000000000800000
Cur core size (bytes) = 0xFFFFFFFFFFFFFFFD
Cur memory size (bytes) = 0xFFFFFFFFFFFFFFFD
nofiles (descriptors) = 0x0000000000010000

Information in this record is only valid at the time when this file was
created (see this record's time stamp)

2015-01-23-07.10.06.488465-360 I1370A888 LEVEL: Error
PID : 5409 TID : 12 PROC : db2sysc
INSTANCE: db2pcni NODE : 000 DB : PCNLIST
APPHDL : 0-7 APPID: *LOCAL.db2pcni.150123131006
AUTHID : DB2PCNI
EDUID : 12 EDUNAME: db2agent (PCNLIST)
FUNCTION: DB2 UDB, data protection services, sqlpgRetrieveLatestLFHRecord, probe:560
MESSAGE : Corresponding checksums don't match
DATA #1 : unsigned integer, 4 bytes
566610918
DATA #2 : unsigned integer, 4 bytes
565955558
DATA #3 : unsigned integer, 4 bytes
565890022
DATA #4 : unsigned integer, 4 bytes
565758950
DATA #5 : Dumped object of size 12288 bytes at offset 0, 49 bytes
/home/db2pcni/sqllib/db2dump/5409.12.000.dump.bin
DATA #6 : Dumped object of size 12288 bytes at offset 12408, 49 bytes
/home/db2pcni/sqllib/db2dump/5409.12.000.dump.bin

2015-01-23-07.10.06.521726-360 I2259A642 LEVEL: Warning
PID : 5409 TID : 12 PROC : db2sysc
INSTANCE: db2pcni NODE : 000 DB : PCNLIST
APPHDL : 0-7 APPID: *LOCAL.db2pcni.150123131006
AUTHID : DB2PCNI
EDUID : 12 EDUNAME: db2agent (PCNLIST)
FUNCTION: DB2 UDB, data protection services, sqlpgRetrieveLatestLFHRecord, probe:560
MESSAGE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
DATA #1 : String, 54 bytes
/db2/pcn_vol1/db2pcni/NODE0000/SQL00001/SQLOGCTL.LFH.1

inherited db2 after our db2 dba left for other opportunities

Db Instance cannot connect to something to do with log file or log header

$
0
0
Db seems to start when I try to connect get error. Here is snippet from db2diag right after db2 connect to DB was executed any ideas. Trying not to have to do a db restore. I inherited DB2 after someone took another opportunity

2015-01-23-07.10.06.488465-360 I1370A888 LEVEL: Error
PID : 5409 TID : 12 PROC : db2sysc
INSTANCE: db2pcni NODE : 000 DB : PCNLIST
APPHDL : 0-7 APPID: *LOCAL.db2pcni.150123131006
AUTHID : DB2PCNI
EDUID : 12 EDUNAME: db2agent (PCNLIST)
FUNCTION: DB2 UDB, data protection services, sqlpgRetrieveLatestLFHRecord, probe:560
MESSAGE : Corresponding checksums don't match
DATA #1 : unsigned integer, 4 bytes
566610918
DATA #2 : unsigned integer, 4 bytes
565955558
DATA #3 : unsigned integer, 4 bytes
565890022
DATA #4 : unsigned integer, 4 bytes
565758950
DATA #5 : Dumped object of size 12288 bytes at offset 0, 49 bytes
/home/db2pcni/sqllib/db2dump/5409.12.000.dump.bin
DATA #6 : Dumped object of size 12288 bytes at offset 12408, 49 bytes
/home/db2pcni/sqllib/db2dump/5409.12.000.dump.bin

2015-01-23-07.10.06.521726-360 I2259A642 LEVEL: Warning
PID : 5409 TID : 12 PROC : db2sysc
INSTANCE: db2pcni NODE : 000 DB : PCNLIST
APPHDL : 0-7 APPID: *LOCAL.db2pcni.150123131006
AUTHID : DB2PCNI
EDUID : 12 EDUNAME: db2agent (PCNLIST)
FUNCTION: DB2 UDB, data protection services, sqlpgRetrieveLatestLFHRecord, probe:560
MESSAGE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
DATA #1 : String, 54 bytes
/db2/pcn_vol1/db2pcni/NODE0000/SQL00001/SQLOGCTL.LFH.1

Office for National Statistics is looking to hire a Chief Data Architect in UK

$
0
0
ONS has Technology at its core

From the economic future of the country, to the provision of public services, statistics are vital to every imaginable area of our lives. And vital to the production and dissemination of these statistics? Technology. Robust, effective, cutting-edge technology. IT is front and centre of ONS, driving modernisation and streamlining operations for all. Our IT professionals – and we employ more than 340 talented, knowledgeable people in technology alone - combining statistical knowledge, methodology, IT and project management to put us at the forefront of government digitalisation and data visualisation. An IT career at ONS is a development opportunity not to be missed!

About you

You’ll have excellent communication skills as well as proven experience of managing and developing the capabilities of a large cross-site teams. You must have substantial demonstrable knowledge and experience of conceptual, logical and physical data modelling techniques along with experience in the implementation phase of data architecture, including data migration and/or data integration processes. You'll also have experience in a range of DBMS, other data repository technologies would be advantageous, and experience in an Oracle environment would be preferred. Also familiarity with data format standards, especially open data standards such as XML, JSON etc. You'll have practical experience in the whole development lifecycle, and will have worked on at least 2 large application development projects in a lead IT role.

About the role

As Chief of Data Architect you will lead a team who will be expected to provide data architecture solutions which are technically correct and in line with our overall vision and strategy. This will include applying data analysis and data modelling techniques in a consistent manner, based upon a detailed understanding of the corporate information requirements, and to identify the most appropriate use of database and other data storage facilities, contributing to practical and feasible overall solutions. To be effective in this role, you will be expected to liaise closely with business and technical development teams, including solution and technical architects. As part of the extended Enterprise Architecture team you will also help to develop, implement and maintain corporate data standards and data architecture principles.

Person specification -
In order to achieve this you will need

IT specialism
Expert in the application of automated (software) tools which enable selective access to information held within some form of database or "data warehouse". Example: Exporting data to a spreadsheet via ODBC.

IT specialism
Expert in Database Software which enables the user to create, populate and manipulate data structures. Examples: Access, SQL Server, DB2, Oracle, Informix, Sybase, MySQL.

IT specialism
Expert in Business Analysis Techniques which help in modelling and understanding a business and its operation. Examples:.conceptual, logical and physical data modelling, functional business models, statistical process control, use cases

Making effective decisions
Resolves (and is accountable for) major, high-risk, problems, can make timely (and difficult or unpopular) decisions with incomplete information and takes decisions forward to implementation.

Leading and Communicating
Is widely acknowledged as displaying leadership qualities and skills that win the commitment of others, maintain organisational cohesion and energise them to achieve the ONS/Authority vision

Building Capability for All
Experience of managing and developing the capabilities of a large cross-site team pool of resources to deliver a technical function ensuring the effective assignment and allocation of resources within project(s)/program(s)

Click on the following link for more information & to apply: https://express.candarine.com/campai...d/088a1339f663

Grouping columns from sql select statement

$
0
0
I am retrieving some data from Invoices, Customers and Companies tables as follows, but would like to make the customerName and the Companies.Name as single column such Name and similarly for customerID/companyID and customerCode/companyCode. Any suggestions please? Thanks.

Code:

with cte
as
(               

        select                distinct i.invoiceNumber, itemID, customers.customerID, Companies.companyID
                                ,SUM(net_weight) as totalWeight, rate
                                ,(select SUM(net_weight) * rate)  as amount
        from                Invoices i inner join InvoicesDetails on i.invoiceID = InvoicesDetails.invoiceID
        LEFT JOIN        Companies ON i.companyID = Companies.companyID
        LEFT JOIN        Customers ON i.customerID = Customers.customerID
        where                DATENAME(month,i.sell_date) = 'January'
        and                        YEAR(i.sell_date) = '2014'
        group by        invoiceNumber, rate, itemID ,customers.customerID,Companies.companyID,rate
)

select                customers.firstname + ' ' + customers.surname as customerName
                        ,customers.code as customerCode
                        ,cte.invoiceNumber,cte.itemID, cte.totalWeight, cte.rate, cte.amount
                        , companies.name
                        , cte.companyID, cte.customerID,
                        Companies.code as companyCode
from                Companies
RIGHT JOIN        cte ON cte.companyID = Companies.companyID
LEFT JOIN        Customers ON cte.customerID = Customers.customerID

Thoughts for speeding up a View?

$
0
0
I've been reading up lately that adding clustered indexes to a view or potentially schemabinding the view to the tables are two really good ways of optimizing the performance of your view.

Right now this thing is massive, so I am a little leery that any optimization is possible, but wanted to bounce these ideas against experienced DBA's.

The underlying table structure should have very little movement if ever, so the schema being bound shouldn't hinder anyone.

Just was curious what your thoughts were? Is it a waste of time, the articles I have been reading seem to be pro schema binding.

Regarding RAM Upgrade for Dell Optiplex 580

$
0
0
Hello everybody. I just wanted a few tips when making a RAM upgrade for a desktop computer.

One of the administrative assistants at my job has to store a lot of files on her C: drive for the President and Chairman of the Board. She is utilizing a Dell Optiplex 580 (Windows 7) with only 2 GB's of installed RAM. I opened the computer and discovered she uses a blue colored Kingston 2 GB 1Rx8 PC3-10600U-9-10-AG memory stick.

If I order her 2 more GB's of memory do I need to use the same manufacturer in conjunction with the one already in there? Do I have to buy Kingston produced RAM? Or does anybody have any suggestions on which 2 GB of RAM I should buy for this computer that is compatible? I have been doing some research and did a system checker and the attached image is what I discovered is compatible.

I just wanted opinions and insights when purchasing RAM so I do not do this often and I want to make sure I buy the right one the firs time around. Any feedback is always appreciated. Thank you.

Form Update chart

$
0
0
Ok I have a main form.

I input some data via combo boxes and then have a macro you click that deletes and subsequentally recreates a table with the list box information.

I also want to have two charts on this form automatically update upon running the macro. However, i always have to close and re open the form to get the charts to update with the new information. Ive been trying to mess around with the charts "event properties", but havent gotten anything to work.

help?

Hi!

$
0
0
Hi DBFOrums,

I am going to be using MYSQL (and ODBC) for a project at work and for some personal projects. I look forward to learning more about databases in general, and just wanted to stop by and say "hi".

Kind Regards,
Ben David

Changing the Admin default username

$
0
0
We have an Access database that we use to track pages for our paper clinical studies. One particular table stores information about special paper forms that we send out to individuals and, in turn, receive back from them. In addition to capturing the sent/received dates, we keep track of who sends and receives these forms. The fields are set up to be auto-populated with the user's name as defined in the user-level security.

A co-worker of mine has been using this database regularly in Access 2003 with Windows XP as her OS. Just the other day, her workstation was upgraded to Access 2010 and Windows 7. The problem is this: When she tabs into those fields designed to capture her username, it's defaulting to "Admin," which is not what we want.

I thought I could go into Database Tools, and click Users and Permissions in the Administer group to try to troubleshoot. But Users and Permissions is nowhere to be found. I'm not sure if this is the correct approach, if it involves the "secured.mdw" file, or if it's something else entirely. Any ideas?

Charge as a BD designer?

$
0
0
Guys,

To the admin: just delete this post if it violates the rules.

Just curious, how much do you charge your clients as a developer of BD applications.
Do you allow your clients to access the design or just provide the compiled app?

Thanks

Ernie

Number of Charaters in a String

$
0
0
Is there a way to get the length of a string? A steer in the right
direction would be appreciated.

Joe

Anyone work in database programming/related field that can answer a few questions?

$
0
0
For a class I'm taking, I need to conduct an interview with someone that works in a related field. Can someone please private msg me if they can help out. I would be very appreciative. Just 4 questions pretty short.

Thanks!

Concatenating data?

$
0
0
I am using php/mysql.
I have a table called ‘entries’ with fields entryid, dateadded, entrytext. There can be any number of entries for any one day.
I want to produce a report where I get all of the ‘entrytext’ entries concatenated for each day in a table rather than the date being repeated a number of times with a single entrytext against each row of the table.

What's a good way to go about doing this?

Many thanks

VBA - Treeview connection (NodeClick Event)

$
0
0
Hello,

First I would start with the fact, that I am quite new to the VBA programming language, normally I tried to avoid it or replicate something existing.
In this case I ran out of any ideas.

I have a form containing 2 treeviews. The difference between them is:

1) Parent + Level 1 Child (treereqs1)
2) Level 1 Child as Parent + all other childs (treereqs2)

Now I have two things which I will never be able to program with my knowledge on my own:

1) If user selects a Level 1 Child from the treeview 1, the second treeview will populate that child with all its further childs and not showing the rest of question (Level 1 Child).
2) When the user reaches the last level of a child, to jump automatically to the next question in treeview1.

If anyone would want to spend some time to support me with the coding, I would be very greatfull.

Cristi

TreeView.zip
Attached Files

DB2 - high system memory usage (Windows)

$
0
0
Hi,

We have DB2 (9.5 LUW) installed on windows server. Few days ago we've noticed the system memory usage suddenly increased from 10 GB used to almost 16 GB used (of 16 GB total). This happened in a very short time of 30 minutes. The situation lasted for several hours until I started a full online database backup (to TSM). As soon as the backup process started, the mem usage immediately drops back to normal 10 GB used in just a few minutes. After a day the usage rised again to about 95-97% of total system physical memory.
The fact that database backup solved the memory problem temporarily, I think points to the core of the problem, but unfortunatelly I not very familiar with memory monitoring on DB2 so I cannot tell which segment caused the trouble. I hope someone can give me a hint where to start to look. Please, advise me what additional information should I collect on the db2 and I will post this here.

I would kindly ask for some help.

Thanks in advance.
BR,
Domen

Grouping of Fields

$
0
0
Hi All,


I have a 3rd Party Table with the following fields
Code:

date            Code1    Time1    Code2    Time2  Code3  Time3    Code4    Time4    Code5  Time5.
01.01.2015    AAA      0:15      CCC        1:00    AAA    0:10                                BBB      0:15
01.01.2015    BBB      0:10      AAA        1:00    EEE      0:10        BBB      0:30      CCC      0:15
02.01.2015    CCC      0:15      CCC        1:00    BBB      0:10      DDD      1:00      AAA      0:15

What I require is to group the Codes and sum the Times for each code based on the text value of the code.
Code:

CODE    DATE1              HOURS2  DATE2        HOURS2
AAA      01.01.2015        1:25      02.01.2015    0:15
BBB      01.01.2015        0:55      02.01.2015    0:10
CCC      01.01.2015        1:15      02.01.2015    1:15
DDD      01.01.2015      0:00      02.01.2015    1:00

The query will alway be run for a week so DATE1-DATE7 and HOURS1-HOURS7 required.

AAA BBB CCC etc can be of multiple options so these can't be hard coded. eg there could be a ZZZ or ZAC etc.

How would I go about this?

Thanks in advance,
Conor

Joining a table twice

$
0
0
Hi

I have tables Companies, CompaniesDetails (the company branches), Addresses and Companies_Addresses.

The addresses table contain street and city while the Companies_Addresses has the keys for both companies and branches ,ie,
they are linked to Companies and CompaniesDetails via CompanyID and CompanyDetailID and to Addresses via addressID.

Companies_Addresses
id (PK)
companyID (FK)
companyDetailID (FK)
addressID (FK)

I am able to get the branch address at the moment with this code but I would like to get the company address as well using a single select statement. Any suggestions please?


Code:

SELECT DISTINCT                Addresses.city as branchCity, Addresses.street as branchStreet
                                                                               
FROM                        Companies
LEFT JOIN                CompaniesDetails AS cd ON companies.companyID = cd.companyID

LEFT JOIN                Companies_Addresses AS c ON c.companyDetailID = cd.companyDetailID
LEFT JOIN                Addresses ON c.addressID = Addresses.addressID

WHERE                        Companies.name LIKE 'abc'
AND                        Companies.status_indicator like 'Current'

SQL assessment

$
0
0
Hello !
Do somebody knows where I can find a SQL assessment test ?

removing duplicates records from a column pouplate randomly

$
0
0
I ran this query to populate a field with random numbers but it keeps populating with some duplicate records. Any idea how I can remove the duplicates?

UPDATE APRFIL
SET ALTATH = CONVERT(int, RAND(CHECKSUM(NEWID())) * 10000);

Below are sample output that I need the dupes not show. The table already exist and its sql 2008
155957
155957
155968
155974
155976
15599
155990
155997
155997
156005
156008
Viewing all 13329 articles
Browse latest View live