Question: I started learning C++ using a ebook and got interupted by a few lines, which I think are a bit outdated. Anyway, what I am trying to do is using a preprocessor directive as a function parameter which isnt working:

```
#define TitleLabelId 1000;

//....

hTitleText = CreateWindow(L"STATIC",
                          L"Test Text",
                          WS_VISIBLE | WS_CHILD,
                          0, 0,
                          300, 20,
                          hWnd,
                          (HMENU)TitleLabelId,
                          hInst,
                          NULL);

```

This gives me an compile error, while this will give me a correct result:

```
HMENU hm = (HMENU)TitleLabelId;

hTitleText = CreateWindow(L"STATIC",
                          L"Test Text",
                          WS_VISIBLE | WS_CHILD,
                          0, 0,
                          300, 20,
                          hWnd,
                          (HMENU)TitleLabelId,
                          hInst,
                          NULL);

```

I tried to outsource the Label Text aswell but unfortunateley it didnt work either using the following directive:

```
#define TitleText L"Blob Color War";

```

Is it anything with the syntax I have overseen? Thanks in advance!

Answer: 
Being a newbie i got the same set of errors.  

It was found that one of the daemons in my case namenode was not initiated.
On installing hadoop it would be wise to make it a habit to hit he following commands :   

ps -ef | grep "namenode"   

ps -ef | grep "datanode"   

ps -ef | grep "tracker"

One needs to check the relevant log if any of the daemon is not working.
I was facing the same issue--used the below steps to resolve it:

1. Create an file hive-site.xml and input the details (for Local/Prod mode). Make sure the below location exist /home/hadoop/bhishm/warehouse

Example:

```
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<configuration>
<property>
    <name>hive.metastore.warehouse.dir</name>
    <value>/home/hadoop/bhishm/warehouse</value>
    <description>
    Local or HDFS directory where Hive keeps table contents.
    </description>
</property>
<property>
    <name>hive.metastore.local</name>
    <value>true</value>
    <description>
    Use false if a production metastore server is used.
    </description>
</property>
<property>
    <name>javax.jdo.option.ConnectionURL</name>
    <value>jdbc:derby:;databaseName=/home/hadoop/bhishm/warehouse/metastore_db;create=true</value>
    <description>
    The JDBC connection URL.
    </description>
</property>
</configuration>

```
2. Edit the hive-env.sh--> add the java path as the first line after reducing memory usage:

Example:

```
# Hive Client memory usage can be an issue if a large number of clients
# are running at the same time. The flags below have been useful in 
# reducing memory usage:

# The java implementation to use.  Required.

export JAVA_HOME=/usr/lib/jvm/java-1.6.0-openjdk

```
3. Run the hive query.